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/?7002","webpack://_N_E/../../libs/shared/mi-headless-utils/src/components/Layout/index.tsx","webpack://_N_E/../../libs/shared/mi-headless-utils/src/components/PageRendererComponent/index.tsx","webpack://_N_E/../../libs/mi-groups-components/src/components/DataLayerWrapper/DataLayerWrapper.tsx","webpack://_N_E/./pages/[[...page]].tsx","webpack://_N_E/../../node_modules/next/head.js"],"sourcesContent":["\n (window.__NEXT_P = window.__NEXT_P || []).push([\n \"/[[...page]]\",\n function () {\n return require(\"private-next-pages/[[...page]].tsx\");\n }\n ]);\n if(module.hot) {\n module.hot.dispose(function () {\n window.__NEXT_P.push([\"/[[...page]]\"])\n });\n }\n ","import Head from 'next/head';\nimport React, { ReactElement, useMemo } from 'react';\n\nexport const siteTitle = 'Marriott';\n\nexport function Layout({\n children,\n title,\n metaNames,\n metaProps,\n staticComponentClientLibsCSS,\n staticComponentClientLibsJS,\n gridCss,\n isAuthorMode,\n canonical = '',\n USE_MOCK_MODEL = false,\n hreflangList = [],\n mainID = '',\n}: {\n children?: ReactElement | Array<ReactElement>;\n title?: string;\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n metaNames: Array<any>;\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n metaProps?: Array<any>;\n staticComponentClientLibsCSS?: string;\n staticComponentClientLibsJS?: string;\n gridCss?: string;\n isAuthorMode?: boolean;\n canonical?: string;\n USE_MOCK_MODEL?: boolean;\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n hreflangList?: Array<any>;\n mainID?: string;\n}) {\n const generateClientLibsHost = useMemo(() => {\n if (String(process.env['IS_LOCAL_DEV']) === 'true' && !isAuthorMode && !USE_MOCK_MODEL) {\n return process.env['NEXT_PUBLIC_AEM_HOST'];\n } else {\n return '';\n }\n }, []);\n\n return (\n <>\n <Head>\n <meta charSet=\"UTF-8\" />\n <link rel=\"icon\" href=\"/favicon.ico\" />\n <title>{title}</title>\n {metaNames?.map(metaName => (\n <meta key={metaName.name} name={metaName.name} content={metaName.value}></meta>\n ))}\n {metaProps?.map(metaProperty => (\n <meta key={metaProperty.name} property={metaProperty.name} content={metaProperty.value}></meta>\n ))}\n <meta name=\"viewport\" content=\"width=device-width, initial-scale=1.0\" />\n {canonical && <link rel=\"canonical\" href={canonical} />}\n <link rel=\"preload\" href={`${generateClientLibsHost}${staticComponentClientLibsCSS}`} as=\"style\" />\n <link rel=\"stylesheet\" href={`${generateClientLibsHost}${staticComponentClientLibsCSS}`} />\n <link rel=\"stylesheet\" href={`${generateClientLibsHost}${gridCss}`} />\n {hreflangList?.map((item, index) => (\n <link rel=\"alternate\" href={item?.href} hrefLang={item?.hreflang} key={`href-lang-list-${index}`} />\n ))}\n </Head>\n <main id={mainID}>{children}</main>\n {staticComponentClientLibsJS && (\n <script src={`${generateClientLibsHost}${staticComponentClientLibsJS}`} defer></script>\n )}\n </>\n );\n}\n","//This returns a component which can be rendered in any product specific [[page.tsx]]\n//to return the page template(Head, main, sections) along with the required react Components mentioned in model.json and\n// load the CSS and JS libs required by static components from AEM.\nimport { ResponsiveGrid } from '@adobe/aem-react-editable-components';\nimport { ApolloProvider } from '@apollo/client';\nimport Head from 'next/head';\nimport { ApolloEnvVars, getDeployedEnvType, useNextMiApolloClient } from '@marriott/mi-apollo-client-utils';\nimport { Layout } from '../Layout';\nimport { respGridUtil } from '../../lib/helpers';\n\n/* eslint-disable @typescript-eslint/no-explicit-any */\nexport function PageRendererComponent({\n model,\n pagePath,\n operationSignatures,\n isAuthorMode,\n USE_MOCK_MODEL,\n apolloEnvVars,\n}: {\n model?: any;\n pagePath?: string;\n operationSignatures?: Array<any>;\n isAuthorMode?: boolean;\n USE_MOCK_MODEL?: boolean;\n apolloEnvVars?: ApolloEnvVars;\n}) {\n const MiApolloClient = useNextMiApolloClient(\n operationSignatures || [],\n apolloEnvVars?.DEPLOYED_ENV_TYPE || getDeployedEnvType(),\n {},\n {},\n apolloEnvVars\n );\n\n const {\n metaNames,\n metaProperties,\n title,\n staticComponentClientLibsCSS,\n staticComponentClientLibsJS,\n gridCss,\n canonical,\n hreflangList,\n }: {\n metaNames: Array<any>;\n metaProperties: Array<any>;\n title: string;\n staticComponentClientLibsCSS: string;\n staticComponentClientLibsJS: string;\n gridCss: string;\n canonical: string;\n hreflangList: Array<any>;\n } = model;\n const respGridModel = respGridUtil(model?.cqItems?.root?.[':items']?.responsivegrid);\n const responsiveGridHeaderModel = model?.cqItems?.root?.[':items']?.['header-responsivegrid']\n ? respGridUtil(model?.cqItems?.root?.[':items']?.['header-responsivegrid'])\n : false;\n const responsiveGridFooterModel = model?.cqItems?.root?.[':items']?.['footer-responsivegrid']\n ? respGridUtil(model?.cqItems?.root?.[':items']?.['footer-responsivegrid'])\n : false;\n\n return (\n <ApolloProvider client={MiApolloClient}>\n <Layout\n metaNames={metaNames}\n metaProps={metaProperties}\n title={title}\n staticComponentClientLibsCSS={staticComponentClientLibsCSS}\n staticComponentClientLibsJS={staticComponentClientLibsJS}\n gridCss={gridCss}\n isAuthorMode={isAuthorMode}\n USE_MOCK_MODEL={USE_MOCK_MODEL}\n canonical={canonical}\n hreflangList={hreflangList}\n >\n <Head>\n <title>{model.title}</title>\n </Head>\n {responsiveGridHeaderModel && (\n <ResponsiveGrid\n {...responsiveGridHeaderModel}\n pagePath={pagePath}\n key={pagePath}\n itemPath=\"root/header-responsivegrid\"\n />\n )}\n <section id=\"main-content\">\n <ResponsiveGrid\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment\n // @ts-ignore\n pagePath={pagePath}\n itemPath=\"root/responsivegrid\"\n key={pagePath}\n model={respGridModel}\n />\n </section>\n {responsiveGridFooterModel && (\n <ResponsiveGrid\n {...responsiveGridFooterModel}\n key={pagePath}\n pagePath={pagePath}\n itemPath=\"root/footer-responsivegrid\"\n />\n )}\n </Layout>\n </ApolloProvider>\n );\n}\n","import React from 'react';\nimport Head from 'next/head';\nimport { getDataLayerScript } from '@marriott/mi-headless-utils';\n\nexport const DataLayerWrapper: React.FC<{\n children: JSX.Element;\n dataLayer: Record<string, string | number | boolean>;\n}> = props => {\n return (\n <>\n <Head>\n <script\n id=\"miDataLayer\"\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n dangerouslySetInnerHTML={{ __html: getDataLayerScript(props?.dataLayer as unknown as any) }}\n ></script>\n </Head>\n {props.children}\n </>\n );\n};\n","import { GetServerSideProps } from 'next';\nimport { useRouter } from 'next/router';\nimport operationSignatures from '../_constants/operationSignatures.json';\nimport { PageRendererComponent, prePageCall } from '@marriott/mi-headless-utils';\nimport { FEATURE_FLAGS, FeatureFlagService, TARGETS } from '@marriott/mi-feature-flag-utils';\nimport { DataLayerWrapper, NEXT_PUBLIC_ENV_KEYS } from '@marriott/mi-groups-components';\nimport { brandSpecificUrls } from '../renderer.config';\n\nfunction PageRenderer(props) {\n const router = useRouter();\n return (\n <DataLayerWrapper {...props}>\n <PageRendererComponent {...props} key={router.asPath} />\n </DataLayerWrapper>\n );\n}\n\n//Any product specific page data apart from common data like session, datalayer\n//can be returned from this function and the same is passed as props to the page Component\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nconst groupsSpecificData = async (context: any) => {\n // to get the dtt flag from Harness FeatureFlagService\n const featureFlagApiKey = process.env['HARNESS_API_KEY'];\n const featureFlagService = new FeatureFlagService(featureFlagApiKey || '');\n const dttFlags: { [key in FEATURE_FLAGS]?: string | boolean | Record<string, unknown> } =\n await featureFlagService.getAllFlags({\n target: TARGETS.APP.GROUPS_RENDERER_DTT,\n });\n\n const isDttEnabledFromHarness = dttFlags[FEATURE_FLAGS.EXPERIENCE_MCOM_DTT_GROUP];\n\n if (isDttEnabledFromHarness) {\n context?.res?.setHeader('Set-Cookie', `dtt=${isDttEnabledFromHarness}; Path=/; Secure; SameSite=None`);\n }\n\n return {\n operationSignatures,\n nextPublicEnvKeys: NEXT_PUBLIC_ENV_KEYS,\n selector: brandSpecificUrls.includes(context.query.page.join('/')) ? context.query.brandCode : null,\n dttFlags,\n };\n};\n\n//Make pre page calls like session, datalayer, fetch model.json, producSpecifc data etc\n//at server side and pass the data is passed as props to page component.\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nexport const getServerSideProps: GetServerSideProps<any> = prePageCall(groupsSpecificData);\nexport default PageRenderer;\n","module.exports = require('./dist/shared/lib/head')\n"],"names":["Layout","children","title","metaNames","metaProps","staticComponentClientLibsCSS","staticComponentClientLibsJS","gridCss","isAuthorMode","canonical","USE_MOCK_MODEL","hreflangList","mainID","generateClientLibsHost","useMemo","String","process","Head","meta","charSet","link","rel","href","map","metaName","name","content","value","metaProperty","property","as","item","index","hrefLang","hreflang","main","id","script","src","defer","PageRendererComponent","model","pagePath","operationSignatures","apolloEnvVars","MiApolloClient","useNextMiApolloClient","DEPLOYED_ENV_TYPE","getDeployedEnvType","metaProperties","respGridModel","respGridUtil","cqItems","root","responsivegrid","responsiveGridHeaderModel","responsiveGridFooterModel","ApolloProvider","client","ResponsiveGrid","key","itemPath","section","DataLayerWrapper","props","dangerouslySetInnerHTML","__html","getDataLayerScript","dataLayer","PageRenderer","router","useRouter","asPath"],"sourceRoot":"","ignoreList":[5]}